import request from '@/utils/request'
 
export const siteList = function(params){
  return request({
    url: '/site/list',
    method: 'get',
    params: params,
  })
}
export const siteAdd = function(params){
  return request({
    url: '/site/add',
    method: 'post',
    data: params,
  })
}
export const siteEditGet = function(params){
  return request({
    url: '/site/edit',
    method: 'get',
    params: params,
  })
}
export const siteEditPost = function(params){
  return request({
    url: '/site/edit',
    method: 'post',
    data: params,
  })
}
export const nameCnList = function(params){
  return request({
    url: '/site/name_cn',
    method: 'get',
    params: params,
  })
}
export const nameEnList = function(params){
  return request({
    url: '/site/name_en',
    method: 'get',
    params: params,
  })
}
export const siteSiteList = function(params){
  return request({
    url: '/site/site',
    method: 'get',
    params: params,
  })
}
export const siteStatusSwitch = function(params){
  let url = '/site/status_switch?id='+params.id
  delete params.id
  return request({
    url: url,
    method: 'post',
    data: params,
  })
}
export const siteDel = function(params){
  return request({
    url: '/site/del',
    method: 'post',
    data: params,
  })
}
export const siteExport = function(params){
  return request({
    url: '/site/export_url',
    method: 'get',
    params: params,
  })
}

export const siteListGet = function(params){
  return request({
    url: '/site/get_site',
    method: 'get',
    params: params,
  })
}
